package com.sikaryofficial.adaptermq.message.body;

import com.alibaba.fastjson2.JSONObject;
import com.fasterxml.jackson.annotation.JsonProperty;
import lombok.Data;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
import lombok.ToString;

import java.util.List;

/**
 * 数据传输消息定义
 */
@NoArgsConstructor
@Data
@Getter
@Setter
@ToString
public class SyncDataMessage{
    @JsonProperty("data")
    private List<JSONObject> data;
    /** 是那个数据库*/
    @JsonProperty("database")
    private String database;
    @JsonProperty("isDdl")
    private Boolean isDdl;
    @JsonProperty("table")
    private String table;
    /**  UPDATE DELETE INSERT*/
    @JsonProperty("type")
    private String type;
    @JsonProperty("pkNames")
    private String[] pkNames;

}
